home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / SourceCode / MiscKit1.7.1 / MiscKit / Palettes / MiscProgressPalette / MiscProgressPieInspector.m < prev    next >
Text File  |  1995-04-12  |  1KB  |  56 lines

  1. //
  2. //    MiscProgressPieInspector.m -- a simple view class for displaying progress
  3. //        Written and Copyright (c) 1993 by James Heiser.  (jheiser@adobe.com)
  4. //                Version 1.0.  All rights reserved.
  5. //
  6. //        This notice may not be removed from this source code.
  7. //
  8. //    This object is included in the MiscKit by permission from the author
  9. //    and its use is governed by the MiscKit license, found in the file
  10. //    "LICENSE.rtf" in the MiscKit distribution.  Please refer to that file
  11. //    for a list of all applicable permissions and restrictions.
  12. //    
  13.  
  14.  
  15. #import "MiscProgressPieInspector.h"
  16. #import "MiscProgressView.subproj/MiscProgressPie.h"
  17.  
  18. @implementation MiscProgressPieInspector
  19.  
  20. - init
  21. {
  22.     char buf[MAXPATHLEN + 1];
  23.     id bundle;
  24.     
  25.     [super init];
  26.     
  27.     bundle = [NXBundle bundleForClass:[MiscProgressPie class]];
  28.     [bundle getPath:buf 
  29.             forResource:"MiscProgressPieInspector" 
  30.             ofType:"nib"];
  31.     [NXApp loadNibFile:buf 
  32.            owner:self 
  33.            withNames:NO 
  34.            fromZone:[self zone]];
  35.     return self;
  36. }
  37.  
  38. - ok:sender
  39. {
  40.     [object setHidden:[theCheckBox intValue]];
  41.     return [super ok:sender];
  42. }
  43.  
  44. - revert:sender
  45. {
  46.     [theCheckBox setState:[object isHidden]];
  47.     return [super revert:sender];
  48. }
  49.  
  50. - (BOOL)wantsButtons
  51. {
  52.     return NO;
  53. }
  54.  
  55. @end
  56.